package demo.mappers;

import demo.entity.employees;
import demo.entity.managers;
import demo.entity.record;
import org.springframework.jdbc.core.RowMapper;



import java.sql.ResultSet;
import java.sql.SQLException;

public class managersRowMapper implements RowMapper<managers> {

    @Override
    public managers mapRow(ResultSet rs,int i) throws SQLException {
        managers man = new managers();
        man.setId(rs.getInt("id"));
        man.setEmp_id(rs.getInt("emp_id"));
        man.setName(rs.getString("name"));
        man.setDepartment_id(rs.getString("department_id"));
        man.setJob_id(rs.getString("job_id"));
        man.setReason(rs.getString("reason"));
        man.setStatus(rs.getString("status"));
        man.setStart_date(rs.getString("start_date"));;
        man.setEnd_date(rs.getString("end_date"));
        man.setApply_time(rs.getString("apply_time"));
        man.setDeal_time(rs.getString("deal_time"));
        return man;
    }
}
